package com.bot.edu.informationmanage.course.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.bot.edu.informationmanage.course.entity.Course;
import com.bot.edu.applysystem.audition.entity.vo.CourseVo;
import com.bot.edu.informationmanage.course.mapper.CourseMapper;
import com.bot.edu.informationmanage.course.service.ICourseService;
import com.bot.edu.informationmanage.cousesection.entity.CourseSection;
import com.bot.edu.informationmanage.cousesection.entity.vo.CourseSectionVo;
import com.bot.edu.informationmanage.majortype.entity.MajorType;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

import java.util.ArrayList;
import java.util.List;

/**
 * @Description: 课程表
 * @Author: jeecg-boot
 * @Date:   2022-03-31
 * @Version: V1.0
 */
@Service
public class CourseServiceImpl extends ServiceImpl<CourseMapper, Course> implements ICourseService {

    @Autowired
    private CourseMapper courseMapper;



    @Override
    public List<CourseSection> getSectionByPid(String sectionId) {
        return courseMapper.getSectionByPid(sectionId);
    }

    @Override
    public List<CourseSectionVo> getCourseSectionById(String courseId) {
        return courseMapper.getCourseSectionById(courseId);
    }

    @Override
    public List<CourseVo> getCourseByMajorId(QueryWrapper<CourseVo> ew) {
        return courseMapper.getCourseByMajorId(ew);
    }

    @Override
    public MajorType selectCourseTypeBymajorTypeId(String majorTypeId) {
        return courseMapper.selectCourseTypeBymajorTypeId(majorTypeId);
    }

}
